/*
 * cube.h
 *
 *  Created on: Mar 19, 2012
 *      Author: soselar
 */

#ifndef CUBE_H_
#define CUBE_H_

#include <fstream>
#include <iostream>
#include <string>
#include <vector>

using namespace std;

class cube
{
public:
	vector<int> element;

	cube& operator = (const cube &rhs){
		element = rhs.element;
		return *this;
	};

	bool operator == (const cube &rhs)
	{
		for (int i = 0; i < element.size(); i++)
			if (element[i] != rhs.element[i])
				return false;
		return true;
	};

	cube(string input)
	{
		for (int i = 0; i < input.size(); i++){
			if (input[i] == '1')
				element.push_back(1);
			else if (input[i] == '0')
				element.push_back(0);
			else if (input[i] == '-')
				element.push_back(2);
		}
	};

	cube(int icount)
	{
		for (int i = 0; i < icount; i++){
			element.push_back(2);
		}
	};

	cube(){};

	void add(int);
	string output();
};

#endif /* CUBE_H_ */
